import { createApp } from 'vue'
import './style.css'
import App from './App.vue'

import router from "./router";
import pinia from "./store";
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
//svg icon
import 'virtual:svg-icons-register'

import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import SvgIcon from './components/SvgIcon/index.vue'


const app = createApp(App)
app.use(router)
app.use(pinia)
//将图标进行全局注册
for (const [key, component] of Object.entries(ElementPlusIconsVue)){
    app.component(key, component)
}

app.component('svg-icon', SvgIcon)
app.use(ElementPlus,{
    locale: zhCn
})
app.mount('#app')
